package cn.tude._05mvcboot04.pojo.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;

@Data
public class UserRegDTO {
    @ApiModelProperty(value = "用户名",required = true)
    @Pattern(regexp = "[\\\\u4e00-\\\\u9fa5a-zA-Z]{3,10}",message = "用户名应该为3~10个字符 的字母和字符串以及他们的组合")
    private String username;
    @ApiModelProperty(value = "密码",required = true)
    @NotBlank(message = "密码不能为 空 空白 空字符串")
    private String password;
    @ApiModelProperty(value = "昵称",required = true)
    @NotBlank(message = "密码不能为 空 空白 空字符串")
    private String nickname;
}
